/*
 * @功能描述: 
 * @版本: v1.0.0
 * @作者: LuAn
 * @Date: 2021-09-02 06:32:14
 * @LastEditTime: 2021-09-02 07:03:37
 */
#if !defined(BSP_UART_H)
#define BSP_UART_H
#include "imx6ul.h"
#define UART_SRC_CLK Val2MHz(80)
void disable_uart(UART_Type *uart);
void enable_uart(UART_Type *uart);
void uart_set_baudrate2(UART_Type *base, uint32_t baudrate, uint32_t srcclock_hz);
void uart_set_baudrate(UART_Type *uart, uint32_t baudrate);
void uart_init(UART_Type *uart, uint32_t baudrate, void (*uart_io_init)(UART_Type *));
void uart_putc(UART_Type *uart, unsigned char c);
void uart_puts(UART_Type *uart, const char *str);
int uart_getc(UART_Type *uart);
#endif // BSP_UART_H
